<#--
	espirit/generic.$json.ftl
	input parameter: properties
	FIXME: security problem from 'properties' ,read the propery parameter from session?
-->
<#assign properties = Parameters.properties?default('')>
<#assign applyToChildModel = Parameters.cascade?default('') == 'true'>
<#assign target = Parameters.target!'execute'>
<#if properties == '' && applyToChildModel == false>
	<#if (target=='execute')>
	    ${fn.json(stack.findValue(target), actionPath)}<#t>
	<#else>
	    ${fn.json(stack.findValue('app'), actionPath)}<#t>
	</#if>
<#else>
	<#if (target=='execute')>
	    ${fn.json(stack.findValue(target), properties, applyToChildModel, target)}<#t>
	<#else>
	    ${fn.json(stack.findValue('app'), properties, applyToChildModel, target)}<#t>
	</#if>
</#if>